#include <iostream>
#include <string>
#include <string_view>

using namespace std;

int main()
{
	string s = "a";
	string_view v = s;
	cout << "[" << v << "] [" << s << "]" << endl;
	s += "b";
	cout << "[" << v << "] [" << s << "]" << endl;
	s[0] = 'c';
	cout << "[" << v << "] [" << s << "]" << endl;
	s.clear();
	s.shrink_to_fit();
	cout << "[" << v << "] [" << s << "]" << endl;

	return 0;
}